# libexpat installed via fink
EXPAT_LIB=/sw/lib/libexpat.a
LIBS="$LIBS -L/sw/lib"
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBEXPAT 1
-_ACEOF
-
fi
if test -f /opt/local/lib/libexpat.a ; then
# libexpat installed via macports
EXPAT_LIB=/opt/local/lib/libexpat.a
LIBS="$LIBS -L/opt/local/lib"
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBEXPAT 1
-_ACEOF
-
fi
if test -f /usr/local/lib/libexpat.a ; then
# libexpat installed from source
EXPAT_LIB=/usr/local/lib/libexpat.a
LIBS="$LIBS -L/usr/local/lib"
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBEXPAT 1
-_ACEOF
-
fi
;;
*-gentoo-freebsd*)
*-*-freebsd*)
if test -f /usr/local/lib/libexpat.a ; then
EXPAT_LIB=/usr/local/lib/libexpat.a
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBEXPAT 1
-_ACEOF
-
fi
;;
esac
fi
-if test "x${EXPAT_LIB}" = x; then
+if ! test "x${EXPAT_LIB}" = x; then
+ { echo "$as_me:$LINENO: result: $EXPAT_LIB" >&5
+echo "${ECHO_T}$EXPAT_LIB" >&6; }
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBEXPAT 1
+_ACEOF
+
+else
{ echo "$as_me:$LINENO: result: try to autodetect" >&5
echo "${ECHO_T}try to autodetect" >&6; }
{ echo "$as_me:$LINENO: checking for XML_ParserCreate in -lexpat" >&5
fi
-else
- { echo "$as_me:$LINENO: result: $EXPAT_LIB" >&5
-echo "${ECHO_T}$EXPAT_LIB" >&6; }
fi
# libexpat installed via fink
EXPAT_LIB=/sw/lib/libexpat.a
LIBS="$LIBS -L/sw/lib"
- AC_DEFINE(HAVE_LIBEXPAT, 1, [Defined if you have libexpat])
fi
if test -f /opt/local/lib/libexpat.a ; then
# libexpat installed via macports
EXPAT_LIB=/opt/local/lib/libexpat.a
LIBS="$LIBS -L/opt/local/lib"
- AC_DEFINE(HAVE_LIBEXPAT, 1, [Defined if you have libexpat])
fi
if test -f /usr/local/lib/libexpat.a ; then
# libexpat installed from source
EXPAT_LIB=/usr/local/lib/libexpat.a
LIBS="$LIBS -L/usr/local/lib"
- AC_DEFINE(HAVE_LIBEXPAT, 1, [Defined if you have libexpat])
fi
;;
*-gentoo-freebsd*)
*-*-freebsd*)
if test -f /usr/local/lib/libexpat.a ; then
EXPAT_LIB=/usr/local/lib/libexpat.a
- AC_DEFINE(HAVE_LIBEXPAT, 1, [Defined if you have libexpat])
fi
;;
esac
]
)
-if test "x${EXPAT_LIB}" = x; then
+if ! test "x${EXPAT_LIB}" = x; then
+ AC_MSG_RESULT($EXPAT_LIB)
+ AC_DEFINE(HAVE_LIBEXPAT, 1, [Defined if you have libexpat])
+else
AC_MSG_RESULT(try to autodetect)
AC_CHECK_LIB([expat], [XML_ParserCreate],
AC_DEFINE(HAVE_LIBEXPAT, 1, [Defined if you have libexpat])
EXPAT_LIB=-lexpat
)
-else
- AC_MSG_RESULT($EXPAT_LIB)
fi
AC_SUBST(EXPAT_LIB)